//2 of 3

//Spending outpoint 0 of multisig tx https://btgexplorer.com/tx/a193319f02818dc8a0d5e5d75ef01018b17b4cf631246c5a5e3ab0d6f190d6ec

node tx.js BTG create prevtx=a193319f02818dc8a0d5e5d75ef01018b17b4cf631246c5a5e3ab0d6f190d6ec prevaddr=APWkFpVPuqSf24m8et1sZvARHXNStB2H8x prevamount=0.00459356 previndex=0 privkey=<privkey1>-<privkey2>-5221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8321039f1e160a02079a6d6b7be0334cc4d76a125cd13a6f8d7131b11c263bc20bf91853ae-2of3 addr=GKz5ii8tWQG9hd196vNkwkLKsWHqaeKSoB fees=0.00000500 amount=0.002

/*
Version BTG
create
--- Previous amount is: 0.00459356
--- Amount to spend is: 0.00200000
--- Network fees are: 0.00000500
--- Dev fees are: 0.00008500
--- Refunded amount to spending address is: 0.00250356
true
Redeemer script verified: APWkFpVPuqSf24m8et1sZvARHXNStB2H8x
----- Transaction hash: 6eede106ab5dc1c88029c49f89052e9cb1608966e898f9f8b783686056640eb3
Transaction body:
0200000001ecd690f1d6b03a5e5a6c2431f64c7bb11810f05ed7e5d5a0c88d81029f3193a100000000fc004730440220372bf8bec30ba0a28117d0003ee4dea0eb6d7f9df32bfcd5d00153a1531578bb02204e65b296f77f15bc6825b6b818c2bcb5453b31f26b6c2fc289a0f79f40cb04da414730440220458eb6387dd1c4be0d2b94df149488db9aa99e1256f39ddc13d86df7e21615ee022014ab40030a239db3bf8e1fa6e54daf88fff34cd990596cd4dfd3d8d3f2c492d1414c695221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8321039f1e160a02079a6d6b7be0334cc4d76a125cd13a6f8d7131b11c263bc20bf91853aeffffffff03400d0300000000001976a914177b585b5401ad21b60b78b1b3c91996f250296d88acf4d103000000000017a91454e498ddf5e6621ef62c3f1ef39b3994a1e421a48734210000000000001976a9145b79a9d29a34f2f284ecdd33009ffa5e0252b68988ac00000000
Complete transaction:
e1476d4474780000000000000000000093010000b30e64560200000001ecd690f1d6b03a5e5a6c2431f64c7bb11810f05ed7e5d5a0c88d81029f3193a100000000fc004730440220372bf8bec30ba0a28117d0003ee4dea0eb6d7f9df32bfcd5d00153a1531578bb02204e65b296f77f15bc6825b6b818c2bcb5453b31f26b6c2fc289a0f79f40cb04da414730440220458eb6387dd1c4be0d2b94df149488db9aa99e1256f39ddc13d86df7e21615ee022014ab40030a239db3bf8e1fa6e54daf88fff34cd990596cd4dfd3d8d3f2c492d1414c695221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8321039f1e160a02079a6d6b7be0334cc4d76a125cd13a6f8d7131b11c263bc20bf91853aeffffffff03400d0300000000001976a914177b585b5401ad21b60b78b1b3c91996f250296d88acf4d103000000000017a91454e498ddf5e6621ef62c3f1ef39b3994a1e421a48734210000000000001976a9145b79a9d29a34f2f284ecdd33009ffa5e0252b68988ac00000000
Size 427 bytes
Network Fees: 500 - 1.17 satoshis/byte
Dev Fees: 8500
------------- Check - deserialize
{ input:
   [ { hash: 'a193319f02818dc8a0d5e5d75ef01018b17b4cf631246c5a5e3ab0d6f190d6ec',
       n: 0,
       scriptSigLen: 252,
       scriptSig: [Object],
       script: [Object],
       nSequence: <Buffer ff ff ff ff> } ],
  output:
   [ { nValue: 200000,
       scriptPubkeyLen: <Buffer 19>,
       scriptPubkey: <Buffer 76 a9 14 17 7b 58 5b 54 01 ad 21 b6 0b 78 b1 b3 c9 19 96 f2 50 29 6d 88 ac>,
       address: 'GKz5ii8tWQG9hd196vNkwkLKsWHqaeKSoB',
       type: 'p2pkh' },
     { nValue: 250356,
       scriptPubkeyLen: <Buffer 17>,
       scriptPubkey: <Buffer a9 14 54 e4 98 dd f5 e6 62 1e f6 2c 3f 1e f3 9b 39 94 a1 e4 21 a4 87>,
       address: 'APWkFpVPuqSf24m8et1sZvARHXNStB2H8x',
       type: 'p2sh' },
     { nValue: 8500,
       scriptPubkeyLen: <Buffer 19>,
       scriptPubkey: <Buffer 76 a9 14 5b 79 a9 d2 9a 34 f2 f2 84 ec dd 33 00 9f fa 5e 02 52 b6 89 88 ac>,
       address: 'GSBbeuKPu4d6HKJhtPgk7XayMcaXyQy8TS',
       type: 'p2pkh' } ],
  s: 0,
  nVersion: <Buffer 02 00 00 00>,
  nbinput: 1,
  nboutput: 3,
  nLockTime: <Buffer 00 00 00 00> }
------------- End Check - deserialize
------------- Check - verify
----- Transaction hash: 6eede106ab5dc1c88029c49f89052e9cb1608966e898f9f8b783686056640eb3
signature: 30440220372bf8bec30ba0a28117d0003ee4dea0eb6d7f9df32bfcd5d00153a1531578bb02204e65b296f77f15bc6825b6b818c2bcb5453b31f26b6c2fc289a0f79f40cb04da
message to be signed: 02000000e28606d035bcb02d88f9709abd1094d4d7cd39e0f83bbcbf4e2e53a563e1b8533bb13029ce7b1f559ef5e747fcac439f1455a2ec7c5f09b72290795e70665044ecd690f1d6b03a5e5a6c2431f64c7bb11810f05ed7e5d5a0c88d81029f3193a100000000695221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8321039f1e160a02079a6d6b7be0334cc4d76a125cd13a6f8d7131b11c263bc20bf91853ae5c02070000000000ffffffff7efb5b668f52be7f0a4e257eb4d5518bc5b193df578d9dea6ac3683f27c5cd5d00000000414f0000
signature: 30440220458eb6387dd1c4be0d2b94df149488db9aa99e1256f39ddc13d86df7e21615ee022014ab40030a239db3bf8e1fa6e54daf88fff34cd990596cd4dfd3d8d3f2c492d1
message to be signed: 02000000e28606d035bcb02d88f9709abd1094d4d7cd39e0f83bbcbf4e2e53a563e1b8533bb13029ce7b1f559ef5e747fcac439f1455a2ec7c5f09b72290795e70665044ecd690f1d6b03a5e5a6c2431f64c7bb11810f05ed7e5d5a0c88d81029f3193a100000000695221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8321039f1e160a02079a6d6b7be0334cc4d76a125cd13a6f8d7131b11c263bc20bf91853ae5c02070000000000ffffffff7efb5b668f52be7f0a4e257eb4d5518bc5b193df578d9dea6ac3683f27c5cd5d00000000414f0000
Multisig signatures verified
Redeemer script verified: APWkFpVPuqSf24m8et1sZvARHXNStB2H8x
Multisig allowed to spend
----- Transaction verified
----- Transaction hash: 6eede106ab5dc1c88029c49f89052e9cb1608966e898f9f8b783686056640eb3
------------- End Check - verify

https://btgexplorer.com/tx/6eede106ab5dc1c88029c49f89052e9cb1608966e898f9f8b783686056640eb3

*/

//2 of 2

//Spending outpoint 0 of multisig tx https://btgexplorer.com/tx/a3bf7ca4d4f4c8d6337ecd34a21c60a7b1457f7bb5c6b043f13800d00dae05ac


node tx.js BTG create prevtx=a3bf7ca4d4f4c8d6337ecd34a21c60a7b1457f7bb5c6b043f13800d00dae05ac prevaddr=APYoozQLELj1eV4JpAE95dTQUGcQNG4XVp prevamount=0.00009433 previndex=0 privkey=<privkey1>-<privkey2>-5221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8352ae-2of2 addr=GKz5ii8tWQG9hd196vNkwkLKsWHqaeKSoB fees=0.00000500

/*
Version BTG
create
--- Prevamount is small, min dev fees of 8300 apply - amount should be 0.00000633
--- Previous amount is: 0.00009433
--- Amount to spend is: 0.00000633
--- Network fees are: 0.00000500
--- Dev fees are: 0.00008300
true
Redeemer script verified: APYoozQLELj1eV4JpAE95dTQUGcQNG4XVp
----- Transaction hash: 760443f19eb3848c510127d802177ac241ec6f3e300404e2b394548899b80992
Transaction body:
0200000001ac05ae0dd00038f143b0c6b57b7f45b1a7601ca234cd7e33d6c8f4d4a47cbfa300000000db00483045022100ff458d739070c2f509d956a38f9062d5bf710a6d2c7f92fd946afbf80ada598c0220016adf1c8eec0e9d65c995ccbb5e58ec8380e267843e55e27af4fba679e7a6f141483045022100965b5a5dfcd3a147728d1f7f8abb9fbad9663c6ec2356a18c80d8af0d0b8d774022047cc77227d469086de710f4ed76605f9a793f8b1132f29764210a88e15165ceb41475221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8352aeffffffff0279020000000000001976a914177b585b5401ad21b60b78b1b3c91996f250296d88ac6c200000000000001976a9145b79a9d29a34f2f284ecdd33009ffa5e0252b68988ac00000000
Complete transaction:
e1476d44747800000000000000000000520100009209b8990200000001ac05ae0dd00038f143b0c6b57b7f45b1a7601ca234cd7e33d6c8f4d4a47cbfa300000000db00483045022100ff458d739070c2f509d956a38f9062d5bf710a6d2c7f92fd946afbf80ada598c0220016adf1c8eec0e9d65c995ccbb5e58ec8380e267843e55e27af4fba679e7a6f141483045022100965b5a5dfcd3a147728d1f7f8abb9fbad9663c6ec2356a18c80d8af0d0b8d774022047cc77227d469086de710f4ed76605f9a793f8b1132f29764210a88e15165ceb41475221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8352aeffffffff0279020000000000001976a914177b585b5401ad21b60b78b1b3c91996f250296d88ac6c200000000000001976a9145b79a9d29a34f2f284ecdd33009ffa5e0252b68988ac00000000
Size 362 bytes
Network Fees: 500 - 1.38 satoshis/byte
Dev Fees: 8300
------------- Check - deserialize
{ input:
   [ { hash: 'a3bf7ca4d4f4c8d6337ecd34a21c60a7b1457f7bb5c6b043f13800d00dae05ac',
       n: 0,
       scriptSigLen: 219,
       scriptSig: [Object],
       script: [Object],
       nSequence: <Buffer ff ff ff ff> } ],
  output:
   [ { nValue: 633,
       scriptPubkeyLen: <Buffer 19>,
       scriptPubkey: <Buffer 76 a9 14 17 7b 58 5b 54 01 ad 21 b6 0b 78 b1 b3 c9 19 96 f2 50 29 6d 88 ac>,
       address: 'GKz5ii8tWQG9hd196vNkwkLKsWHqaeKSoB',
       type: 'p2pkh' },
     { nValue: 8300,
       scriptPubkeyLen: <Buffer 19>,
       scriptPubkey: <Buffer 76 a9 14 5b 79 a9 d2 9a 34 f2 f2 84 ec dd 33 00 9f fa 5e 02 52 b6 89 88 ac>,
       address: 'GSBbeuKPu4d6HKJhtPgk7XayMcaXyQy8TS',
       type: 'p2pkh' } ],
  s: 0,
  nVersion: <Buffer 02 00 00 00>,
  nbinput: 1,
  nboutput: 2,
  nLockTime: <Buffer 00 00 00 00> }
------------- End Check - deserialize
------------- Check - verify
----- Transaction hash: 760443f19eb3848c510127d802177ac241ec6f3e300404e2b394548899b80992
signature: 3045022100ff458d739070c2f509d956a38f9062d5bf710a6d2c7f92fd946afbf80ada598c0220016adf1c8eec0e9d65c995ccbb5e58ec8380e267843e55e27af4fba679e7a6f1
message to be signed: 020000002f923bdec767c536d08a82cc800babf7f25f3007a8aa43ead993e9747088d8153bb13029ce7b1f559ef5e747fcac439f1455a2ec7c5f09b72290795e70665044ac05ae0dd00038f143b0c6b57b7f45b1a7601ca234cd7e33d6c8f4d4a47cbfa300000000475221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8352aed924000000000000ffffffff1e4aa7b3539c696b60ae2aa063f04791c520f0dbf0a88fe558df9465b3d5075900000000414f0000
signature: 3045022100965b5a5dfcd3a147728d1f7f8abb9fbad9663c6ec2356a18c80d8af0d0b8d774022047cc77227d469086de710f4ed76605f9a793f8b1132f29764210a88e15165ceb
message to be signed: 020000002f923bdec767c536d08a82cc800babf7f25f3007a8aa43ead993e9747088d8153bb13029ce7b1f559ef5e747fcac439f1455a2ec7c5f09b72290795e70665044ac05ae0dd00038f143b0c6b57b7f45b1a7601ca234cd7e33d6c8f4d4a47cbfa300000000475221021254e3173d3351fa283d10c82042686f43e739933ab19860b479316ffbba57482102267d15316f752c73f80dac185a872463563f0c16457062de1be4d1e513442e8352aed924000000000000ffffffff1e4aa7b3539c696b60ae2aa063f04791c520f0dbf0a88fe558df9465b3d5075900000000414f0000
Multisig signatures verified
Redeemer script verified: APYoozQLELj1eV4JpAE95dTQUGcQNG4XVp
Multisig allowed to spend
----- Transaction verified
----- Transaction hash: 760443f19eb3848c510127d802177ac241ec6f3e300404e2b394548899b80992
------------- End Check - verify

https://btgexplorer.com/tx/760443f19eb3848c510127d802177ac241ec6f3e300404e2b394548899b80992

*/
